package com.ceba.test.modules.filemanage.entity;


import com.ceba.base.web.entity.IBase;
import com.ceba.test.base.utils.CebaFileManageUtil;

public class GFolder extends IBase{
	private static final long serialVersionUID = 8177852187268294140L;

	private String id;
	
	//父目录关联ID
	private String pId;
	
	private String name;
	
	private String folderName;
	
	private String relationFolder;
	
	private String userId;
	
	private String classS;
	
	private String img;
	
	private String readSql;
	
	private String reportId;
	
	private String createTime;
	
	private String createUser;
	
	//-------------------------------
	private String type;

	private String fileName;
	
	private String filePath;
	
	private String size;
	
	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public String getPId() {
		return pId;
	}

	public void setPId(String pId) {
		this.pId = pId;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getFolderName() {
		return folderName;
	}

	public void setFolderName(String folderName) {
		this.folderName = folderName;
	}

	public String getRelationFolder() {
		return relationFolder;
	}

	public void setRelationFolder(String relationFolder) {
		this.relationFolder = relationFolder;
	}

	public String getUserId() {
		return userId;
	}

	public void setUserId(String userId) {
		this.userId = userId;
	}

	public String getClassS() {
		return classS;
	}

	public void setClassS(String classS) {
		this.classS = classS;
	}

	public String getImg() {
		return img;
	}

	public void setImg(String img) {
		this.img = img;
	}

	public String getReadSql() {
		return readSql;
	}

	public void setReadSql(String readSql) {
		this.readSql = readSql;
	}

	public String getReportId() {
		return reportId;
	}

	public void setReportId(String reportId) {
		this.reportId = reportId;
	}

	public String getCreateTime() {
		return createTime;
	}

	public void setCreateTime(String createTime) {
		this.createTime = createTime;
	}

	public String getCreateUser() {
		return createUser;
	}

	public void setCreateUser(String createUser) {
		this.createUser = createUser;
	}

	public String getType() {
		return type;
	}

	public void setType(String type) {
		this.type = type;
	}

	public String getFileName() {
		return fileName;
	}

	public void setFileName(String fileName) {
		this.fileName = fileName;
	}

	public String getFilePath() {
		return filePath;
	}

	public void setFilePath(String filePath) {
		this.filePath = filePath;
	}

	public String getSize() {
		return size;
	}

	public void setSize(String size) {
		this.size = size;
	}

	public static GFolder createGFolder(String id, String path, String folderName, String pid,String classString,String loginUserId) throws Exception {
		GFolder gf = new GFolder();
		gf.setId(id);
		gf.setName(path);
		gf.setFolderName(CebaFileManageUtil.filterFolderName(folderName));
		gf.setPId(pid);
		gf.setClassS(classString);
		gf.setUserId(loginUserId);
		return gf;
	}
	
}
